﻿using Unity.Commons.Client.Threading;
using Xunit;

namespace Unity.Commons.Client.Tests.Threading
{
    public class ResourceTaskTest
    {
        private static bool TestResourceCommand()
        {
            return true;
        }

        private static bool TestResourceCondition()
        {
            return true;
        }

        [Fact]
        public void MethodsTest()
        {
            ResourceTask testResourceTask = new ResourceTask(TestResourceCommand, TestResourceCondition);
            Assert.True(testResourceTask.IsNeedRun() && testResourceTask.Run());
        }

    }
}
